using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Box : MonoBehaviour
{

    SpriteRenderer spriteRenderer;
    public Sprite boxOpenSprite;
    public GameObject knife;
    // Start is called before the first frame update
    void Start()
    {
        spriteRenderer = GetComponent<SpriteRenderer>();  
        knife.SetActive(false);      
    }

    public void OnGetBoxKey(Unit_Item_Ctrl unit_Item_Ctrl){
        unit_Item_Ctrl.gameObject.SetActive(false);
        spriteRenderer.sprite = boxOpenSprite;
        knife.SetActive(true);
    }

}
